<?php
define('IN_ECS', true);

require(dirname(dirname(__FILE__)) . '/includes/init.php');

$sql = 'SELECT * from tage_integral_goods';
$sqll = 'SELECT cid,cname from tage_integral_com';
$sqlid = 'SELECT goods_sn,goods_name,market_price from tage_goods where is_delete = 0';
$stores = 'SELECT StoreID,StoreName from tage_stores where ProvinceID = "2" and Status = 1 order by DistrictID asc';
$stoRes = $db -> getAll($stores);
$goods = $db->getAll($sql);
$partner = $db->getAll($sqll);
$goodslist = $db->getAll($sqlid);
//var_dump($goods);
//var_dump($stoRes);


$smarty->assign("goodsid","$goodsid");
$smarty->assign("integralvalue","$integralvalue");
$smarty->assign("price","$price");
$smarty->assign("saleprice","$saleprice");
$smarty->assign("begintime", "$begintime");
$smarty->assign("endtime","$endtime");
$smarty->assign("CID","$CID");
$smarty->assign("STOREID","$STOREID");
$smarty->assign("boundprice","$boundprice");
$smarty->assign("typ", "$typ");
$smarty->assign("expiredays","$expiredays");

$smarty->assign('citylist',$stoRes);
$smarty->assign('goods',$goods);
$smarty->assign('partner',$partner);
$smarty->assign('goodslist',$goodslist);
$smarty->display('jfactivity_add.dwt');
?>